Skip to content

feat(i18n): add Bulgarian language support - #3506

Merged
proddy merged 1 commit into
emsesp:devfrom
aibott:feat/bg-localization
Dec 1, 2026
Merged

proddy merged 1 commit into
emsesp:devfrom
aibott:feat/bg-localization

Conversation

@aibott

@aibott aibott commented Dec 1, 2026 •

Copy link
Copy Markdown

Hi everyone,

Thank you for all the work on EMS-ESP! I use EMS-ESP with my Bosch Condens 2300 boiler and would like to contribute Bulgarian (bg) language support so Bulgarian-speaking users can monitor and configure their heating systems in their native language.

Summary

Bulgarian translations and registration

  • Web UI: Added a complete Bulgarian translation (interface/src/i18n/bg/index.ts) covering all 770 Web UI keys with Bulgarian plural rules and consistent terminology (10,093 bytes / ~10.1 KB compressed for the Bulgarian locale chunk; locale chunk size only, not total PR overhead).
  • Firmware: Appended the bg column across all 874 translated device, entity, and word entries in src/core/locale_translations.h (including localized БГВ and ОК circuit tags), registered EMSESP_LOCALE_BG in src/core/system.cpp, and respected existing UTF-8 byte buffer limits for booleans and command logging.
  • Integration & docs: Registered Bulgarian in the Web UI language selectors, entity language list, frontend i18n/build scripts, mock API, README.md, and CHANGELOG_LATEST.md. Generated files (WWWData.h, i18n-*.ts*) remain untracked per .gitignore.

Supporting localization changes

  • Shared grammar and status hooks: Added the shared status, count and grammatical-form hooks needed for Bulgarian, with regression checks covering English, German, Polish and Czech.
  • Dashboard & Devices: Added Bulgarian БГВ and ОК circuit-tag support for grouping and prefix stripping in both Admin and Guest views while keeping untagged labels and user-defined names containing spaces intact. Added 'вкл.' to active boolean detection, and sentence-cased the two Bulgarian maintenance labels on the Dashboard Notes card (Режим на обслужване, Време до следващо обслужване) without modifying lowercase core entity names.
  • Locale-aware date and number formatting: Updated display formatting in interface/src/utils/time.ts and its UI call sites so dates and numbers follow the selected UI locale (for example, DD.MM.YYYY, decimal comma, and space thousands grouping in Bulgarian) while keeping editable inputs, API payloads, and MQTT values unchanged. Note that this intentionally adapts displayed date and number formatting across other languages according to the active UI locale.

Testing

  • Fresh frontend checks on this submission: Verified key/placeholder/buffer parity, typesafe-i18n, Prettier, tsc --noEmit, eslint . (0 errors), English casing check, and the production Web UI build (vite build + progmem-generator.js + size-report.js).
  • Firmware build: Built the s_16M target (original ESP32, 16 MB flash, no PSRAM) directly from this rebased v3.10.0-dev.15 submission with 0 C/C++ compiler warnings.
  • Manual live desktop UI review: Installed the custom s_16M v3.10.0-dev.14 (r5) build on my EMS gateway connected to a Bosch Condens 2300 boiler and reviewed the Bulgarian desktop Web UI across Dashboard, Devices, Sensors, Customizations, Commands, Scheduler, Custom Entities, Status, Settings, Help, and Profile. The live screenshots below were captured from that dev.14 r5 build; the rebased v3.10.0-dev.15 candidate was verified with automated UI regression testing and a fresh s_16M firmware build. Not every EMS device type or physical control command was tested on hardware.
  • Automated mock-data UI checks: Verified desktop, tablet, and mobile viewports, Admin and Guest roles, mixed UI/firmware languages, boolean states, spaced custom names, and English/German/Polish/Czech regressions in headless Chromium against the compiled production bundle (0 page errors, 0 horizontal overflows). Tablet and mobile coverage is automated only.
  • Pending checks: Native C++ tests and fuzzing (native-test, native-fuzz) were not run locally on Windows and remain pending in GitHub Actions.

Screenshots

01-dashboard

Dashboard overview (live desktop capture with Bosch Condens 2300) showing Hot Water, Heating, and Service cards, including complete Bulgarian maintenance labels (Режим на обслужване and Време до следващо обслужване).

02-profile

User Profile page showing Bulgarian (Български) selected in the language grid and the browser-scope subtitle (Променя езика само в този браузър).

03-devices

Devices page displaying live Bosch Condens 2300 parameters with Bulgarian entity translations and localized values.

04-scheduler

Scheduler dialog showing Bulgarian schedule types, weekday abbreviations, callouts, and actions.

Test setup 05-test-setup-esp32-gateway

Custom ESP32 EMS gateway used for the live UI review with a Bosch Condens 2300.

Thanks again for maintaining EMS-ESP — I am happy to adjust any Bulgarian wording or implementation details after review.

Checklist

  • Pull request targets the dev branch.
  • Changes are scoped to Bulgarian localization and its supporting UI localization hooks (unrelated hardware changes excluded).
  • Frontend formatting, TypeScript, ESLint, and production Web UI build checks pass locally.
  • Changelog entry prepared in CHANGELOG_LATEST.md and README.md language count updated.
  • GitHub Actions CI checks (pr_check.yml native tests/fuzzing and webui_check.yml) pass on the PR branch.
  • I have read and accept the Contributor License Agreement (CLA) in CONTRIBUTING.md.

@aibott
aibott marked this pull request as ready for review December 1, 2026 10:14
@aibott
aibott force-pushed the feat/bg-localization branch from 12025c5 to e7fc3b5 Compare December 1, 2026 13:48
@proddy

proddy commented Dec 1, 2026

Copy link
Copy Markdown
Contributor

good job! I like that you used the UI locale and not the browser's native locale. I'll merge and we can fix forward if necessary

@proddy
proddy merged commit 9d5350c into emsesp:dev Dec 1, 2026
@aibott

aibott commented Dec 1, 2026

Copy link
Copy Markdown
Author

Thank you, proddy! I really appreciate the feedback and the quick merge.

I'm happy to see Bulgarian support become part of EMS-ESP. I'll continue testing it on my setup and will be happy to help with any follow-up improvements if needed.

Thanks again for all your work on the project!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants